const prod = require("./gulp/prod");
const dev = require("./gulp/dev");
const server = require("./gulp/tasks/server");
const gulp = require("gulp");
const sourcemaps = require("gulp-sourcemaps");

function defaultTask(cb) {
    cb();
    console.log("task default");
}

exports.default = defaultTask;
exports.dev = dev;
exports.prod = prod;
exports.server = server;
exports.series = function(){
    gulp.series(dev, server);
}
//str 为 DestroyableTransform
var str = gulp.src("./src/less/*.less");
// console.log("gulp.src 生成可读流:")
// console.log(str);

//dev 任务为什么是 undefined
// gulp.task(dev);
console.log(gulp.task("dev"))

gulp.task("a", function(){
    console.log("我是任务a.")
})
gulp.task("b", function(){
    console.log("我是任务a.")
})
gulp.task("c", function(){
    console.log("我是任务a.")
})
gulp.task("d", function(){
    console.log("我是任务a.")
})


exports.default = function(){
    console.log("I am default before");
    gulp.series("a","b","c")
    console.log("I am default after");
}